# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=py3-pyldap
_pkgname=python-ldap
pkgver=3.2.0
pkgrel=1
pkgdesc="Python modules for implementing LDAP clients"
url="https://github.com/python-ldap/python-ldap"
arch="all"
options="!check" # depends on slapdtest
license="Python-2.0"
depends="libldap py3-asn1 py3-asn1-modules"
makedepends="python3-dev py3-setuptools openldap-dev"
checkdepends="openldap openldap-clients"
source="https://github.com/$_pkgname/$_pkgname/archive/$_pkgname-$pkgver.tar.gz"
replaces="py-pyldap"
provides="py-pyldap=$pkgver-r$pkgrel"
builddir="$srcdir/$_pkgname-$_pkgname-$pkgver"

build() {
	python3 setup.py build
}

check() {
	python3 setup.py test
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="142ac4f98dfad62abb9ce47822771b4e431e4d86251f7139d99d92d0005cd6c2c1bec2b12e7ab96aa2f9d044e68623d4ddeecfc3a1820c19cd163ddd89355cd0  python-ldap-3.2.0.tar.gz"
